package cn.gson.school.dao.zhaosheng;

import java.util.List;

import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.CrudRepository;
import org.springframework.stereotype.Repository;

import cn.gson.school.entity.xitong.UserInfoEntity;
import cn.gson.school.entity.zhaosheng.FollowupEntity;

/**
 * 招生模块--跟进记录Dao
 */
@Repository
public interface FollowupDao extends CrudRepository<FollowupEntity, Long> {
	List<FollowupEntity> findByUserinfoName(UserInfoEntity userinfo);
	//查询
	@Query(value="from FollowupEntity where year(followTime)= ?1")
	List<FollowupEntity> chaXunAllfollowone(Integer year);
	
	@Query(nativeQuery = true, value = "select * from tb_zs_followup where student_id=?1")
	FollowupEntity jiuyegenjin(Long id);
}
